import store from '@/store'
export const tableOption = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  selection:true,
  arrow:false,
  searchMenuSpan: 6,
  height: 450,
  "column": [
    {
      "type": "input",
      "label": "唯一标识",
      "prop": "id",
      hide: true,
    }, {
      "type": "input",
      "label": "线路编码不能重复",
      "prop": "lineCode",
      hide: true,
    }, {
      "type": "input",
      "label": "车站编码不能重复",
      "prop": "stationCode",
      hide: true,
    }, {
      "type": "select",
      "label": "TVM编号",
      "prop": "tvmCode",
      search: true,
      dicUrl: '/support/swpmtvmcode/page',
      props: {
        label: 'tvmCode',
        value: 'tvmCode',
        res: 'data.records'
      },
	  dicQuery: {
		  size: -1,
		  stationCode: store.getters.userInfo.stationCode,
		  //status: '1'
	  }
    }, {
      "type": "datetime",
      "label": "清点时间",
      "prop": "checkTime",
      format: 'yyyy-MM-dd HH:mm:ss',
      valueFormat: 'yyyy-MM-dd HH:mm:ss',
      width:90
    }, {
      "type": "date",
      "label": "收益日期",
      "prop": "revenueTime",
      "search":true,
      format: 'yyyy-MM-dd',
      valueFormat: 'yyyy-MM-dd',
      width:90
    }, {
      "type": "number",
      "label": "清点金额",
      "prop": "checkAmount",
      precision: 2
    }, {
      "type": "input",
      "label": "清点人1员ID",
      "prop": "checkPersonOneId",
      hide: true,
    }, {
      "type": "input",
      "label": "清点人2员ID",
      "prop": "checkPersonTwoId",
      hide: true,
    }, {
      // "type": "input",
      // "label": "清点人1",
      // "prop": "checkPersonOneName"
      "type": "select",
      "label": "清点人1",
      "prop": "checkPersonOneName",
      params: {
        userCodeKey: 'checkPersonOneJopNo'
      },
      component: 'user-select',
      search: true,
    }, {
      "type": "input",
      "label": "清点人1工号",
      "prop": "checkPersonOneJopNo",
      width:90
    }, {
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      search: true,
    }, {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      width:90
    }, {
      "type": "select",
      "label": "状态",
      "prop": "approvalStatus",
      dicData: [{
        label: "未提交",
        value: "0"
      }, {
        label: "已提交",
        value: "1"
      }],
      search: true,
      searchValue:'0'
    }, {
      "type": "select",
      "label": "确认状态",
      "prop": "confirmStatus",
      dicData: [{
        label: "未确认",
        value: "0"
      }, {
        label: "已确认",
        value: "1"
      }],
      search: true,
      display: false
    }, {
      "type": "input",
      "label": "可用于修改次数的判断，也可用于乐观锁",
      "prop": "version",
      hide: true,
    }, {
      "type": "input",
      "label": "创建人ID",
      "prop": "creatorId",
      hide: true,
      display: false,
    },	{
      width: 120,
      hide: false,
      label: '是否加入报表差错',
      prop: 'isAddReprotError',
      type:'select',
      dicData: [{
        label: '是',
        value: '1'
      },{
        label: '否',
        value: '0'
      }],
    }, {
      hide: false,
      label: '报表修改状态',
      prop: 'reportModifyStatus',
      type:'select',
      search: true,
	  searchLabelWidth: 100,
      dicData: [{
        label: '修改中',
        value: '1'
      },{
        label: '已完成',
        value: '0'
      }],
      width:95
    },{
      "type": "input",
      "label": "备注",
      "prop": "remark",
      width:150
    }, {
      "type": "input",
      "label": "部门ID",
      "prop": "deptId",
      hide: true,
      display: false,
    }, {
      "type": "input",
      "label": "创建人名称",
      "prop": "creatorName",
      hide: true,
      display: false,
    }, {
      "type": "input",
      "label": "创建时间",
      "prop": "createTime",
      hide: false,
      display: false,
      width:90
    }, {
      "type": "input",
      "label": "更新时间",
      "prop": "updateTime",
      hide: false,
      display: false,
      width:90
    }, {
      "type": "input",
      "label": "删除标志 1：删除 0：未删",
      "prop": "delFlag",
      hide: true,
      display: false,
    }]
}

export const formCheckOption = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  submitBtn: false,
  emptyBtn: false,
  labelWidth: 120,
  "column": [{
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      rules: [
        {
          required: true,
          message: "请选择清点人2！",
          trigger: "blur"
        }
      ]
    }, 
    {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      disabled: true
    },
    {
      type: "datetime",
      label: "清点时间",
      prop: "checkTime",
      format: "yyyy-MM-dd HH:mm:ss",
      valueFormat: "yyyy-MM-dd HH:mm:ss",
      rules: [
        {
          required: true,
          message: "请选择清点时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "date",
      label: "收益时间",
      prop: "revenueTime",
      format: "yyyy-MM-dd",
      valueFormat: "yyyy-MM-dd",
      rules: [
        {
          required: true,
          message: "请选择收益时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "textarea",
      label: "备注",
      prop: "remark",
      span: 24
    }
  ]
}

export const formCheckOptionRecords = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  submitBtn: false,
  emptyBtn: false,
  addBtn: false,
  editBtn: false,
  delBtn: false,
  refreshBtn: false,
  labelWidth: 120,
  "column": [{
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      rules: [
        {
          required: true,
          message: "请选择清点人2！",
          trigger: "blur"
        }
      ]
    }, 
    {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      disabled: true
    },
    {
      type: "datetime",
      label: "清点时间",
      prop: "checkTime",
      format: "yyyy-MM-dd HH:mm:ss",
      valueFormat: "yyyy-MM-dd HH:mm:ss",
      rules: [
        {
          required: true,
          message: "请选择清点时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "date",
      label: "收益时间",
      prop: "revenueTime",
      format: "yyyy-MM-dd",
      valueFormat: "yyyy-MM-dd",
      rules: [
        {
          required: true,
          message: "请选择收益时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "textarea",
      label: "备注",
      prop: "remark",
      span: 24
    }
  ]
}

export const formCheckOptionEdit = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  submitBtn: false,
  emptyBtn: false,
  labelWidth: 120,
  "column": [{
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      rules: [
        {
          required: true,
          message: "请选择清点人2！",
          trigger: "blur"
        }
      ]
    }, 
    {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      disabled: true
    },
    {
      type: "datetime",
      label: "清点时间",
      prop: "checkTime",
      format: "yyyy-MM-dd HH:mm:ss",
      valueFormat: "yyyy-MM-dd HH:mm:ss",
      rules: [
        {
          required: true,
          message: "请选择清点时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "date",
      label: "收益时间",
      prop: "revenueTime",
      format: "yyyy-MM-dd",
      valueFormat: "yyyy-MM-dd",
      disabled: true
    },
    {
      type: "textarea",
      label: "备注",
      prop: "remark",
      span: 24
    }
  ]
}

export const formCheckOptionDetailRecords = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  submitBtn: false,
  emptyBtn: false,
  labelWidth: 120,
  "column": [{
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      rules: [
        {
          required: true,
          message: "请选择清点人2！",
          trigger: "blur"
        }
      ]
    }, 
    {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      disabled: true
    },
    {
      type: "datetime",
      label: "清点时间",
      prop: "checkTime",
      format: "yyyy-MM-dd HH:mm:ss",
      valueFormat: "yyyy-MM-dd HH:mm:ss",
      rules: [
        {
          required: true,
          message: "请选择清点时间！",
          trigger: "blur"
        }
      ]
    },
    {
      type: "date",
      label: "收益时间",
      prop: "revenueTime",
      format: "yyyy-MM-dd",
      valueFormat: "yyyy-MM-dd",
      disabled: true
    },
    {
      type: "textarea",
      label: "备注",
      prop: "remark",
      span: 24
    }
  ]
}

export const formCheckOptionView = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  submitBtn: false,
  emptyBtn: false,
  labelWidth: 120,
  "column": [{
      "type": "select",
      "label": "清点人2",
      "prop": "checkPersonTwoName",
      params: {
        userCodeKey: 'checkPersonTwoJopNo'
      },
      component: 'user-select',
      disabled: true
    }, 
    {
      "type": "input",
      "label": "清点人2工号",
      "prop": "checkPersonTwoJopNo",
      disabled: true
    },
    {
      type: "datetime",
      label: "清点时间",
      prop: "checkTime",
      format: "yyyy-MM-dd HH:mm:ss",
      valueFormat: "yyyy-MM-dd HH:mm:ss",
      disabled: true
    },
    {
      type: "date",
      label: "收益时间",
      prop: "revenueTime",
      format: "yyyy-MM-dd",
      valueFormat: "yyyy-MM-dd",
      disabled: true
    },
    {
      type: "textarea",
      label: "备注",
      prop: "remark",
      span: 24,
      disabled: true
    }
  ]
}



